package com.cliang.tools.encription;

import org.junit.jupiter.api.Test;

import java.io.UnsupportedEncodingException;
import java.security.NoSuchAlgorithmException;

class EncriptionTest {
    String a="123456";

    @Test
    void encryptionByMD5() throws UnsupportedEncodingException, NoSuchAlgorithmException {
        System.out.println("MD5加密："+ Encription.encryptionByMD5(a));
    }

    @Test
    void encryptionBySHA256() throws UnsupportedEncodingException, NoSuchAlgorithmException {
        System.out.println("SHA-256加密:"+Encription.encryptionBySHA256(a));
    }

    @Test
    void encodeByMD5(){
        System.out.println("MD5加密："+Encription.encodeByMD5(a));
    }
}